#!/bin/sh

mcu() {
  oraygpio -p 1
#gpiob-20
  oraygpio -H -G B -N 20
#gpiob-21
  oraygpio -H -G B -N 21
}

led() {
#指示灯 gpio 模式
echo 0
}

start() {
  mcu
  led
}

stop() {
  return 0
}

case "$1" in
start)
  start > /dev/null
  ;;
stop)
  stop
  ;;
restart | reload)
  stop
  start
  ;;
mcu)
  mcu
  ;;
led)
  led
  ;;
*)
  echo "Usage: $0 {start|stop|restart|mcu|led}"
  exit 1
  ;;
esac

exit $?
